<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <title>Title</title>
</head>
<body >
<h1 style="margin: auto">Test.jsp</h1>
<h2>${sessionScope.msg == null}</h2>
    <h2><c:out value="${sessionScope.msg}"></c:out>1</h2>
    <c:if test="${sessionScope.data == null}">
        <h2 style="color: red">sessionScope中没有设置data的值</h2>
    </c:if>
    <c:if test="${sessionScope.data != null}">
        <h2 style="color: green">${sessionScope.data}</h2>
    </c:if>

    <h2><c:out value="${sessionScope.data}"></c:out>1</h2>
    <h2><c:out value="${requestScope.msg}"></c:out>1</h2>
    <h2><c:out value="${requestScope.data}"></c:out>1</h2>

<table border="1">
    <tr>
        <td>编号</td>
        <td>姓名</td>
        <td>密码</td>
    </tr>
    <tr>
        <td>${requestScope.list[0].uid}</td>
        <td>${requestScope.list[0].uname}</td>
        <td>${requestScope.list[0].pwd}</td>
    </tr>
   <c:forEach items="${requestScope.list}" var="item">
       <tr>
           <td>${item.uid}</td>
           <td>${item.uname}</td>
           <td>${item.pwd}</td>
       </tr>
   </c:forEach>
</table>
</body>
</html>
